package com.lekang.dto;

import com.lekang.common.core.domain.entity.SysUser;
import com.lekang.domain.Elderly;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.lekang.common.annotation.Excel;
import java.math.BigDecimal;
import java.util.Date;
import java.util.List;

/**
 * 床位联查DTO（含房间、楼层、房型、老人、护理员）
 * @author ruoyi
 * @date 2025-10-18
 */
public class BedDTO {
    private static final long serialVersionUID = 1L;

    /** 床位ID */
    @Excel(name = "床位ID")
    private Long bedId;

    /** 床位号 */
    @Excel(name = "床位号")
    private String bedNo;

    /** 床位状态(0:空闲 1:已占用) */
    @Excel(name = "床位状态")
    private Long bedStatus;

    /** 房间ID */
    @Excel(name = "房间ID")
    private Long roomId;

    /** 房间号 */
    @Excel(name = "房间号")
    private String roomNo;

    /** 房间总床位数 */
    @Excel(name = "房间总床位数")
    private Integer totalBeds;

    /** 房间已入住床位数 */
    @Excel(name = "已入住床位数")
    private Integer occupiedBeds;

    /** 楼层ID */
    @Excel(name = "楼层ID")
    private Long floorId;

    /** 楼层名称 */
    @Excel(name = "楼层名称")
    private String floorName;

    /** 房型ID */
    @Excel(name = "房型ID")
    private Long roomTypeId;

    /** 房型名称 */
    @Excel(name = "房型名称")
    private String roomType;

    /** 床位费用 */
    @Excel(name = "床位费用")
    private BigDecimal bedFee;

    /** 房型介绍 */
    @Excel(name = "房型介绍")
    private String roomDescription;

    /** 房型创建时间 */
    @Excel(name = "房型创建时间")
    private Date createTime;

    /** 模糊查询关键词 */
    private String searchKey;

    /** 床位绑定的老人 */
    private Elderly elderly;

    /** 床位绑定的护理员列表 */
    private List<SysUser> caregivers;
    private Long elderlyId;       // 老人ID
    private String elderlyName;   // 老人姓名

    public String getStayPeriod() {
        return stayPeriod;
    }

    public void setStayPeriod(String stayPeriod) {
        this.stayPeriod = stayPeriod;
    }

    public String getCareLevel() {
        return careLevel;
    }

    public void setCareLevel(String careLevel) {
        this.careLevel = careLevel;
    }

    private String careLevel;      // 护理等级名称（如“一级护理”）
    private String stayPeriod;     // 入住期限（格式：2025-01-01~2025-12-31）


    public Long getElderlyId() {
        return elderlyId;
    }

    public void setElderlyId(Long elderlyId) {
        this.elderlyId = elderlyId;
    }

    public String getElderlyName() {
        return elderlyName;
    }

    public void setElderlyName(String elderlyName) {
        this.elderlyName = elderlyName;
    }

    // Getter + Setter
    public Elderly getElderly() { return elderly; }
    public void setElderly(Elderly elderly) { this.elderly = elderly; }
    public List<SysUser> getCaregivers() { return caregivers; }
    public void setCaregivers(List<SysUser> caregivers) { this.caregivers = caregivers; }
    public String getSearchKey() { return searchKey; }
    public void setSearchKey(String searchKey) { this.searchKey = searchKey; }
    public Long getBedId() { return bedId; }
    public void setBedId(Long bedId) { this.bedId = bedId; }
    public String getBedNo() { return bedNo; }
    public void setBedNo(String bedNo) { this.bedNo = bedNo; }
    public Long getBedStatus() { return bedStatus; }
    public void setBedStatus(Long bedStatus) { this.bedStatus = bedStatus; }
    public Long getRoomId() { return roomId; }
    public void setRoomId(Long roomId) { this.roomId = roomId; }
    public String getRoomNo() { return roomNo; }
    public void setRoomNo(String roomNo) { this.roomNo = roomNo; }
    public Integer getTotalBeds() { return totalBeds; }
    public void setTotalBeds(Integer totalBeds) { this.totalBeds = totalBeds; }
    public Integer getOccupiedBeds() { return occupiedBeds; }
    public void setOccupiedBeds(Integer occupiedBeds) { this.occupiedBeds = occupiedBeds; }
    public Long getFloorId() { return floorId; }
    public void setFloorId(Long floorId) { this.floorId = floorId; }
    public String getFloorName() { return floorName; }
    public void setFloorName(String floorName) { this.floorName = floorName; }
    public Long getRoomTypeId() { return roomTypeId; }
    public void setRoomTypeId(Long roomTypeId) { this.roomTypeId = roomTypeId; }
    public String getRoomType() { return roomType; }
    public void setRoomType(String roomType) { this.roomType = roomType; }
    public BigDecimal getBedFee() { return bedFee; }
    public void setBedFee(BigDecimal bedFee) { this.bedFee = bedFee; }
    public String getRoomDescription() { return roomDescription; }
    public void setRoomDescription(String roomDescription) { this.roomDescription = roomDescription; }
    public Date getCreateTime() { return createTime; }
    public void setCreateTime(Date createTime) { this.createTime = createTime; }

    @Override
    public String toString() {
        return "BedDTO{" +
                "bedId=" + bedId +
                ", bedNo='" + bedNo + '\'' +
                ", bedStatus=" + bedStatus +
                ", roomId=" + roomId +
                ", roomNo='" + roomNo + '\'' +
                ", totalBeds=" + totalBeds +
                ", occupiedBeds=" + occupiedBeds +
                ", floorId=" + floorId +
                ", floorName='" + floorName + '\'' +
                ", roomTypeId=" + roomTypeId +
                ", roomType='" + roomType + '\'' +
                ", bedFee=" + bedFee +
                ", roomDescription='" + roomDescription + '\'' +
                ", createTime=" + createTime +
                ", searchKey='" + searchKey + '\'' +
                ", elderly=" + elderly +
                ", caregivers=" + caregivers +
                ", elderlyId=" + elderlyId +
                ", elderlyName='" + elderlyName + '\'' +
                '}';
    }
//    @Override
//    public String toString() {
//        return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
//                .append("bedId", bedId)
//                .append("bedNo", bedNo)
//                .append("bedStatus", bedStatus)
//                .append("roomId", roomId)
//                .append("roomNo", roomNo)
//                .append("totalBeds", totalBeds)
//                .append("occupiedBeds", occupiedBeds)
//                .append("floorId", floorId)
//                .append("floorName", floorName)
//                .append("roomTypeId", roomTypeId)
//                .append("roomType", roomType)
//                .append("bedFee", bedFee)
//                .append("roomDescription", roomDescription)
//                .append("createTime", createTime)
//                .append("elderly", elderly)
//                .append("caregivers", caregivers)
//                .toString();
//    }
}